//package com.zmn.oms.admin.controller.work.modify;
//
//import com.zmn.oms.admin.controller.work.WorkBaseController;
//import com.zmn.oms.common.constant.OrderConsts;
//import com.zmn.oms.common.dto.ResultDTO;
//import com.zmn.oms.common.exception.OmsBaseException;
//import com.zmn.oms.model.dto.work.modify.must.ZsUpdateStatusDTO;
//import com.zmn.oms.model.vo.work.OperatePermissionVO;
//import com.zmn.oms.model.vo.work.modify.must.ZsUpdateStatusVO;
//import com.zmn.oms.zmn.business.interfaces.work.ZsOrderWorkOperatePermissionBService;
//import com.zmn.oms.zmn.normal.business.interfaces.work.customwork.ZsNormalCustomWorkBService;
//import org.springframework.beans.factory.annotation.Autowired;
//import org.springframework.stereotype.Controller;
//import org.springframework.web.bind.annotation.RequestBody;
//import org.springframework.web.bind.annotation.RequestMapping;
//import org.springframework.web.bind.annotation.ResponseBody;
//import org.springframework.web.servlet.ModelAndView;
//
//import javax.validation.Valid;
//
///**
// * 类描述：工单改状态
// *
// * @author liuying
// * @date 2018/12/10 17:45
// * @modify lujia
// * @deprecated  去掉改状态接口 通过分单撤回操作
// */
//@Controller
//@RequestMapping("/work/modify")
//@Deprecated
//public class WorkUpdateStatusController extends WorkBaseController {
//
//    @Autowired
//    private ZsNormalCustomWorkBService zsNormalCustomWorkBService;
//    @Autowired
//    private ZsOrderWorkOperatePermissionBService orderWorkOperatePermissionBService;
//
//    /**
//     * 改状态
//     */
//    @RequestMapping(value = "/status")
//    public ModelAndView updateStatus(Long orderId, Long workId) throws OmsBaseException {
//        ModelAndView mv = new ModelAndView("work/modify/update_status");
//
//        ZsUpdateStatusVO updateStatusVO = zsNormalCustomWorkBService.findUpdateStatus(workId, orderId);
//
//        mv.addObject("orderId", orderId);
//        mv.addObject("workId", workId);
//        mv.addObject("vo", updateStatusVO);
//        return mv;
//    }
//
//    /**
//     * 保存改状态
//     */
//    @RequestMapping(value = "/save/status")
//    @ResponseBody
//    public ResultDTO saveConfirm(@RequestBody @Valid ZsUpdateStatusDTO zsUpdateStatusDTO) {
//
//        OperatePermissionVO operatePermission = orderWorkOperatePermissionBService.getOperatePermission(zsUpdateStatusDTO.getOrderId(), zsUpdateStatusDTO.getWorkId(), OrderConsts.ORDER_OP_TYPE_UPDATE_STATUS);
//        if (!operatePermission.getCanOperate()) {
//            return ResultDTO.fail(operatePermission.getMsg());
//        }
//
//        zsNormalCustomWorkBService.saveUpdateStatus(zsUpdateStatusDTO);
//        return ResultDTO.success();
//    }
//
//}
